<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>title</title>
    <link rel="stylesheet" type="text/css" href="../css/api.css"/>
    <style>
    	body{
    		
    	}
    </style>
</head>
<body>
	
</body>
<script type="text/javascript" src="../script/api.js"></script>
<script type="text/javascript">
	apiready = function(){
	        var lo = 116.4021310000;
	        var la = 39.9994480000;
			var str = "[{id:1,lon:"+lo+",lat:"+la+"}]";
            var array = [];
            var jsonObject = {id:1,lon:lo,lat:la};
            array.push(jsonObject);
			var map = api.require('bMap');
			map.open({
			    rect: {
			        x: 0,
			        y: 0,
			        w: 320,
			        h: 300
			    },
			    center: {
			        lon: 116.4021310000,
			        lat: 39.9994480000
			    },
			    zoomLevel: 16,
			    showUserLocation: true,
			    fixedOn: api.frameName,
			    fixed: true
			}, function(ret) {
			    if (ret.status) {
			        //alert('地图打开成功');
				        map.addAnnotations({
						    annotations: array,
						    icon: '',
						    draggable: false
						}, function(tt) {
						    if (tt) {
						        //alert(ret.id);
						    }
						});
			    }
			});
	};
</script>
</html>